from flask import Flask

app = Flask(__name__)

# 路由动态参数
# 格式@app.route("/类型:变量名")

@app.route("/<int:number>")
def hello(number):
    return "the int is %s"%number

@app.route("/<float:number>")
def hello2(number):
    return "the float is %s"%number

# 接收一个字符串，不写path，默认就是path
@app.route("/<path:number>")
def hello3(number):
    return "the path is %s"%number

if __name__ == '__main__':
    app.run(debug=True)